package com.baizhi.entity;

import java.io.Serializable;
import java.util.Date;

public class Product implements Serializable {
    private Integer pid;
    private String pname;
    private Double price;
    private Integer count;//存货
    private Integer status;//状态 0上架 1下架
    private Date addDate;
    private String picPath;//图片路径
    private String pdesc;//商品描述
    private Category category;

    public Product() {
    }

    public Product(Integer pid, String pname, Double price, Integer count, Integer status, Date addDate, String picPath, String pdesc, Category category) {
        this.pid = pid;
        this.pname = pname;
        this.price = price;
        this.count = count;
        this.status = status;
        this.addDate = addDate;
        this.picPath = picPath;
        this.pdesc = pdesc;
        this.category = category;
    }

    public Integer getPid() {
        return pid;
    }

    public void setPid(Integer pid) {
        this.pid = pid;
    }

    public String getPname() {
        return pname;
    }

    public void setPname(String pname) {
        this.pname = pname;
    }

    public Double getPrice() {
        return price;
    }

    public void setPrice(Double price) {
        this.price = price;
    }

    public Integer getCount() {
        return count;
    }

    public void setCount(Integer count) {
        this.count = count;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Date getAddDate() {
        return addDate;
    }

    public void setAddDate(Date addDate) {
        this.addDate = addDate;
    }

    public String getPicPath() {
        return picPath;
    }

    public void setPicPath(String picPath) {
        this.picPath = picPath;
    }

    public String getPdesc() {
        return pdesc;
    }

    public void setPdesc(String pdesc) {
        this.pdesc = pdesc;
    }

    public Category getCategory() {
        return category;
    }

    public void setCategory(Category category) {
        this.category = category;
    }

    @Override
    public String toString() {
        return "Product{" +
                "pid=" + pid +
                ", pname='" + pname + '\'' +
                ", price=" + price +
                ", count=" + count +
                ", status=" + status +
                ", addDate=" + addDate +
                ", picPath='" + picPath + '\'' +
                ", pdesc='" + pdesc + '\'' +
                ", category=" + category +
                '}';
    }
}
